package com.xinqizhi.service.impl;

import com.xinqizhi.mapper.SysRoleMapper;
import com.xinqizhi.entity.SysRole;
import com.xinqizhi.service.SysRoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SysRoleServiceImpl implements SysRoleService {

	@Autowired
	private SysRoleMapper roleMapper;

	@Override
	public List<SysRole> getRoleData() {
		return roleMapper.getRoleData();
	}

	/**
	 * 通过角色ID查询role
	 * @param roleid
	 * @return
	 */
	@Override
	public List<SysRole> getRoleDataByRoleid(Integer roleid) {
		return roleMapper.getRoleDataByRoleid(roleid);
	}

	/**
	 * 修改单个角色信息
	 * @param role
	 * @return
	 */
	@Override
	public Boolean updataRole(SysRole role) {
		return roleMapper.updataRole(role);
	}

	/**
	* 需要新功能可以在此实现自定义方法
	*/

}
